<?php
namespace Home\Controller;
use Think\Controller;
class IndexController extends Controller {
    /*APP提交功能首页*/
    public function index(){

        $this->display('common/css');
        $this->display('common/js');
        $this->display();
    }
    /*开始任务数据入库操作*/
    public function upload_start(){
        $m = M('upload');
        $data = I('post.');
        $result = $m->add($data);
        if($result){
            echo json_encode(array('status'=>1,'msg'=>'操作成功！'));
            die();
        }else{
            echo json_encode(array('status'=>0,'msg'=>'操作失败！'));
            die();
        }
    }
    /*接受图片验证后返回，可多次调用*/
    public function validate(){
        $result = $this->doupimgs();
        echo json_encode($result);exit;
        /*调用API的URL地址*/
        $url = '';
        $curl_data = $this->curl_post($url,$result);

    }

}